<script setup lang="ts">
import {listType} from "@/views/ai/agent/x6/content-renderer";
import {McpResponse} from "@/views/ai/agent/x6/mcp/types";
import McpRenderer from "@/views/ai/agent/x6/mcp/mcp-renderer";

const props = defineProps({
  item:Object as PropType<listType>
});
const mcpResults=computed(()=>{
  return  props.item?.chunk?.filter(c=>c.node==='MCP_RES').map(c=>c.data?.responses)[0] as McpResponse[]
})

</script>

<template>
  <div>
    <McpRenderer v-for="r in mcpResults" :mcpResult="r" :key="r.id"/>
  </div>
</template>

<style scoped lang="scss">

</style>
